From: Jasper St. Pierre Date: Thu, 22 Aug 2013 19:38:28 +0000 (-0400) Subject: loginManager: Remove login manager versions of PowerOff/Reboot X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~1013^2^2~3643 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=ce768241da80dd0b8af39635c1f28b62aabcf0dc;p=gnome-shell.git loginManager: Remove login manager versions of PowerOff/Reboot These don't go through gnome-session, so they don't properly update its state machine. We should use these in the future when we want to use logind user sessions, but for now, they're just a trap. https://bugzilla.gnome.org/show_bug.cgi?id=706612 --- diff --git a/js/misc/loginManager.js b/js/misc/loginManager.js index ce4af41e4..62357eafb 100644 --- a/js/misc/loginManager.js +++ b/js/misc/loginManager.js @@ -8,21 +8,9 @@ const Shell = imports.gi.Shell; const Signals = imports.signals; const SystemdLoginManagerIface = - - - - - - - - - - - - @@ -159,24 +147,6 @@ const LoginManagerSystemd = new Lang.Class({ })); }, - canPowerOff: function(asyncCallback) { - this._proxy.CanPowerOffRemote(function(result, error) { - if (error) - asyncCallback(false); - else - asyncCallback(result[0] != 'no'); - }); - }, - - canReboot: function(asyncCallback) { - this._proxy.CanRebootRemote(function(result, error) { - if (error) - asyncCallback(false); - else - asyncCallback(result[0] != 'no'); - }); - }, - canSuspend: function(asyncCallback) { this._proxy.CanSuspendRemote(function(result, error) { if (error) @@ -195,14 +165,6 @@ const LoginManagerSystemd = new Lang.Class({ }); }, - powerOff: function() { - this._proxy.PowerOffRemote(true); - }, - - reboot: function() { - this._proxy.RebootRemote(true); - }, - suspend: function() { this._proxy.SuspendRemote(true); }, @@ -264,24 +226,6 @@ const LoginManagerConsoleKit = new Lang.Class({ })); }, - canPowerOff: function(asyncCallback) { - this._proxy.CanStopRemote(function(result, error) { - if (error) - asyncCallback(false); - else - asyncCallback(result[0]); - }); - }, - - canReboot: function(asyncCallback) { - this._proxy.CanRestartRemote(function(result, error) { - if (error) - asyncCallback(false); - else - asyncCallback(result[0]); - }); - }, - canSuspend: function(asyncCallback) { asyncCallback(false); }, @@ -290,14 +234,6 @@ const LoginManagerConsoleKit = new Lang.Class({ asyncCallback([]); }, - powerOff: function() { - this._proxy.StopRemote(); - }, - - reboot: function() { - this._proxy.RestartRemote(); - }, - suspend: function() { this.emit('prepare-for-sleep', true); this.emit('prepare-for-sleep', false);